import { BlockType } from '@/types/api';
import { radioNum } from '@/types/filter';

export default () => {
  // 过滤数据
  const tabValue = ref<BlockType>('');
  const radioValue = ref(`${radioNum.short},${radioNum.medium},${radioNum.long}`);
  const isShowTurnover = ref(false);
  const setTabValue = (value: BlockType) => {
    tabValue.value = value;
  };
  const setRadioValue = (value: string) => {
    // 处理tableDataArr数据
    radioValue.value = value;
  };
  const setShowTurnover = (value: boolean) => {
    isShowTurnover.value = value;
  };
  return {
    tabValue,
    radioValue,
    isShowTurnover,
    setTabValue,
    setRadioValue,
    setShowTurnover
  };
};
